# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Andy Postnikov <apostnikov@gmail.com>
pkgname=py3-charset-normalizer
pkgver=2.0.10
pkgrel=0
pkgdesc="offers you an alternative to Universal Charset Encoding Detector, also known as Chardet"
url="https://github.com/ousret/charset_normalizer"
arch="noarch"
license="MIT"
depends="python3"
makedepends="py3-setuptools"
checkdepends="py3-pytest-cov"
options="!check" # py3-pytest-cov is not in main repository
source="https://files.pythonhosted.org/packages/source/c/charset-normalizer/charset-normalizer-$pkgver.tar.gz"
builddir="$srcdir/charset-normalizer-$pkgver"

build() {
	python3 setup.py build
}

check() {
	pytest
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="
ee4934978a7939d7d4575dc0018b4c92f1c43fff45e3976907c21937b0a3db03d2d19d3e13431f59b5dfb86b14fac9665767433577c1bd3d4eca1f3c88d74ab5  charset-normalizer-2.0.10.tar.gz
"
